<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
 <head>
  <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  <title>Get and/or set the current session save path</title>

 </head>
 <body><div class="manualnavbar" style="text-align: center;">
 <div class="prev" style="text-align: left; float: left;"><a href="function.session-register.html">session_register</a></div>
 <div class="next" style="text-align: right; float: right;"><a href="function.session-set-cookie-params.html">session_set_cookie_params</a></div>
 <div class="up"><a href="ref.session.html">Session 函数</a></div>
 <div class="home"><a href="index.html">PHP Manual</a></div>
</div><hr /><div id="function.session-save-path" class="refentry">
 <div class="refnamediv">
  <h1 class="refname">session_save_path</h1>
  <p class="verinfo">(PHP 4, PHP 5)</p><p class="refpurpose"><span class="refname">session_save_path</span> &mdash; <span class="dc-title">Get and/or set the current session save path</span></p>

 </div>
 
 <div class="refsect1 description" id="refsect1-function.session-save-path-description">
  <h3 class="title">说明</h3>
  <div class="methodsynopsis dc-description">
   <span class="type">string</span> <span class="methodname"><strong>session_save_path</strong></span>
    ([ <span class="methodparam"><span class="type">string</span> <code class="parameter">$path</code></span>
  ] )</div>

  <p class="para rdfs-comment">
   <span class="function"><strong>session_save_path()</strong></span> returns the path of the current
   directory used to save session data. 
  </p>
 </div>


 <div class="refsect1 parameters" id="refsect1-function.session-save-path-parameters">
  <h3 class="title">参数</h3>
  <p class="para">
   <dl>

    
     <dt>
<em><code class="parameter">path</code></em></dt>

     <dd>

      <p class="para">
       Session data path. If specified, the path to which data is saved will
       be changed. <span class="function"><strong>session_save_path()</strong></span> needs to be called
       before <span class="function"><a href="function.session-start.html" class="function">session_start()</a></span> for that purpose.
      </p>
      <p class="para">
       <blockquote class="note"><p><strong class="note">Note</strong>: 
        <p class="para">
         On some operating systems, you may want to specify a path on a
         filesystem that handles lots of small files efficiently. For example,
         on Linux, reiserfs may provide better performance than ext2fs.
        </p>
       </p></blockquote>
      </p>
     </dd>

    
   </dl>

  </p>
 </div>


 <div class="refsect1 returnvalues" id="refsect1-function.session-save-path-returnvalues">
  <h3 class="title">返回值</h3>
  <p class="para">
   Returns the path of the current directory used for data storage.
  </p>
 </div>


 <div class="refsect1 seealso" id="refsect1-function.session-save-path-seealso">
  <h3 class="title">参见</h3>
  <p class="para">
   <ul class="simplelist">
    <li class="member">
     The <a href="session.configuration.html#ini.session.save-path" class="link">session.save_path</a>
     configuration directive
    </li>
   </ul>
  </p>
 </div>


</div><hr /><div class="manualnavbar" style="text-align: center;">
 <div class="prev" style="text-align: left; float: left;"><a href="function.session-register.html">session_register</a></div>
 <div class="next" style="text-align: right; float: right;"><a href="function.session-set-cookie-params.html">session_set_cookie_params</a></div>
 <div class="up"><a href="ref.session.html">Session 函数</a></div>
 <div class="home"><a href="index.html">PHP Manual</a></div>
</div></body></html>
